import { createRouter, createWebHashHistory } from 'vue-router'
import HomeView from '../views/home.vue'

const router = createRouter({
  history: createWebHashHistory(import.meta.env.BASE_URL),
  routes: [
    {
      path: '/',
      name: 'home',
      component: HomeView,
      meta: {
        show: true,
      }
    },
    {
      path: '/class',
      name: 'class',
      component: () => import('../views/class.vue'),
      meta: {
        show: true,
      }
    },
    {
      path: '/tools',
      name: 'tools',
      component: () => import('../views/tools.vue'),
      meta: {
        show: true,
      }
    },
    {
      path: '/class-table',
      name: 'class-table',
      component: () => import('../views/class-table.vue'),
      meta: {
        show: true,
      }
    },
    {
      path: '/message',
      name: 'message',
      component: () => import('../views/message.vue'),
      meta: {
        show: true,
      }
    },
    {
      path: '/peoples',
      name: 'peoples',
      component: () => import('../views/peoples.vue'),
      meta: {
        show: true,
      }
    },
    {
      path: '/settings',
      name: 'settings',
      component: () => import('../views/settings.vue'),
      meta: {
        show: true,
      }
    },
    {
      path: '/file-upload',
      name: 'file-upload',
      component: () => import('../views/fileUpload.vue'),
      meta: {
        show: true,
      }
    },
    {
      path: '/on-msg',
      name: 'on-msg',
      component: () => import('../views/on-msg.vue'),
      meta: {
        show: false,
      }
    },
    {
      path: '/class-table-gui',
      name: 'about',
      component: () => import('../views/ctg.vue'),
      meta: {
        show: false,
      }
    },
    {
      path: '/tools/youdao',
      name: 'tyoudao',
      component: () => import('../views/tools/youdao.vue'),
      meta: {
        show: true,
      }
    },
    {
      path: '/tools/renjiao',
      name: 'trenjiao',
      component: () => import('../views/tools/renjiao.vue'),
      meta: {
        show: true,
      }
    },
  ]
})

export default router
